package com.itheima.pojo;

import java.io.Serializable;
import java.sql.Date;
import java.util.HashSet;
import java.util.Set;

/**
 * 用户
 */
public class User implements Serializable {
    private Integer id; // 主键
    private String gender; // 性别
    private String username; // 用户名，唯一
    private String password; // 密码
    private String remark; // 备注
    private String station; // 状态
    private String telephone; // 联系电话
    private Date createDate;//用户创建日期
    private String realName;//用户真实姓名
    private Set<Role> roles = new HashSet<Role>(0);//对应角色集合
    private Integer loginNumber;// 登陆次数统计


    public User(Integer id, String gender, String username, String password, String remark, String station,
                String telephone, Date createDate, String realName, Set<Role> roles, Integer loginNumber) {
        this.id = id;
        this.gender = gender;
        this.username = username;
        this.password = password;
        this.remark = remark;
        this.station = station;
        this.telephone = telephone;
        this.createDate = createDate;
        this.realName = realName;
        this.roles = roles;
        this.loginNumber = loginNumber;


    }

    public User(Integer id, String gender, String username, String password, String remark, String station,
                String telephone, Date createDate, String realName, Integer loginNumber) {
        this.id = id;
        this.gender = gender;
        this.username = username;
        this.password = password;
        this.remark = remark;
        this.station = station;
        this.telephone = telephone;
        this.createDate = createDate;
        this.realName = realName;
        this.loginNumber = loginNumber;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public String getStation() {
        return station;
    }

    public void setStation(String station) {
        this.station = station;
    }

    public String getTelephone() {
        return telephone;
    }

    public void setTelephone(String telephone) {
        this.telephone = telephone;
    }

    public Set<Role> getRoles() {
        return roles;
    }

    public void setRoles(Set<Role> roles) {
        this.roles = roles;
    }

    public Date getCreateDate() {
        return createDate;
    }

    public void setCreateDate(Date createDate) {
        this.createDate = createDate;
    }

    public String getRealName() {
        return realName;
    }

    public void setRealName(String realName) {
        this.realName = realName;
    }

    public Integer getLoginNumber() {
        return loginNumber;
    }

    public void setLoginNumber(Integer loginNumber) {
        this.loginNumber = loginNumber;
    }
}
